<!DOCTYPE html>
<html lang="ch" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>焕新网</title>
    <link href="/assets/css/bootstrap.min.css" rel="stylesheet" crossorigin="anonymous">
    <script src="/assets/js/bootstrap.bundle.min.js"  crossorigin="anonymous"></script>
    <link href="/assets/css/main.css" rel="stylesheet">
</head>


<body>
<div class="container">
    <nav class="navbar navbar-expand-lg bg-body-tertiary">
        <div class="container-fluid">
            <a class="navbar-brand" href="#">焕新网</a>
            <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarScroll" aria-controls="navbarScroll" aria-expanded="false" aria-label="Toggle navigation">
                <span class="navbar-toggler-icon"></span>
            </button>
            <div class="collapse navbar-collapse" id="navbarScroll">
                <ul class="navbar-nav me-auto my-2 my-lg-0 navbar-nav-scroll" style="--bs-scroll-height: 100px;">
                    <li class="nav-item">
                        <a class="nav-link active" aria-current="page" th:href="@{'/list?uid='+${user.id}}">首页</a>
                    </li>

                    <li class="nav-item dropdown">
                        <a class="nav-link" th:href="@{'/commodityList?uid='+${user.id}}" >我的订单</a>
                    </li>
                    <li class="nav-item dropdown">
                        <a class="nav-link" th:href="@{'/inidle?uid='+${user.id}}" >我的闲置</a>
                    </li>
                    <li class="nav-item dropdown">
                        <a class="nav-link" th:href="@{'/publish?uid='+${user.id}}">上架商品</a>
                    </li>

                </ul>
                <ul class="navbar-nav d-flex">
                    <li class="nav-item dropdown">
                        <a class="nav-link dropdown-toggle" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
                            个人中心
                        </a>
                        <ul class="dropdown-menu">
                            <li><a class="dropdown-item" th:href="@{'/personaldata?uid='+${user.id}}">基本信息</a></li>

                            <li><hr class="dropdown-divider"></li>
                            <li><a class="dropdown-item" th:href="@{'/login'}">注销登录</a></li>
                        </ul>
                    </li>
                </ul>
                <div class="user">
                    <img src="/assets/images/header.jpg" alt=""width="50" height="auto">
                    <span th:text="${user.nickname}"></span>
                </div>
            </div>
        </div>
    </nav>
</div>
<div th:text="${message}" class="error"></div>
<div class="login-container">
    <form th:action="'/searchResult?uid='+${user.id}" th:method="'post'" class="login-form">
        <div th:text="${message}" class="error"></div>
        <h2 style="color:red" class="text-center">搜索</h2>

        <div class="form-item row" >
            <div class="form-item row" >
                <label for="account" class="col-sm-2 col-form-label">手机号</label>
                <div class="col-sm-10">
                    <input type="text" class="form-control" id="account" placeholder="请输入商品名" name="name">
                </div>
            </div>
        </div>
        <div class="form-item">
            <button type="submit" class="btn btn-primary login-submit">搜索</button>
        </div>
    </form>
</div>
</body>
</html>